<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp" %>

<form:form commandName="formHeads" cssClass="form-horizontal" role="form" onsubmit="return false;">
    <div class="form-group" style="padding-left: 50px;">
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="checkAll" name="" value="">
            <label for="checkAll" class="no-padding">全选</label>
        </div>
    </div>
    <div class="form-group" style="padding-left: 50px;">
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="projectName" name="exportHead" value="projectName">
            <label for="projectName" class="no-padding">消息名称</label>
        </div>
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="type" name="exportHead" value="type">
            <label for="type" class="no-padding">类别</label>
        </div>
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="resDept" name="exportHead" value="resDept">
            <label for="resDept" class="no-padding">收件单位</label>
        </div>
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="recipients" name="exportHead" value="recipients">
            <label for="recipients" class="no-padding">收件人</label>
        </div>
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="phone" name="exportHead" value="phone">
            <label for="phone" class="no-padding">电话号码</label>
        </div>
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="text" name="exportHead" value="text">
            <label for="text" class="no-padding">短信内容</label>
        </div>
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="createDate" name="exportHead" value="createDate">
            <label for="createDate" class="no-padding">日期</label>
        </div>
        <div class="checkbox col-sm-2 ">
            <input type="checkbox" id="createTime" name="exportHead" value="createTime">
            <label for="createTime" class="no-padding">时间</label>
        </div>

    </div>

</form:form>

<script>

    $(function () {
        $("#checkAll").click(function () {
            $("input[name='exportHead']").prop("checked", $(this).prop("checked"));
        });

    })
</script>



